<!DOCTYPE html>
<html lang="zh-cmn-Hans">
<head>
<title>请选择入口</title>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=0">
<meta http-equiv="Cache-Control" content="no-cache" />
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<link rel="stylesheet" href="/static/css/weui.min.css">
<link rel="stylesheet" href="/static/css/jquery-weui.min.css">
</head>
<body>
<div id="container" style="margin-left: 25%; width: 50%;">
	<div class="weui-cells__title">请选择入口</div>
	<div class="weui-cells">
		<div class="weui-cell weui-cell_access" id="fundtool" onclick="redirectTo(this);">
			<div class="weui-cell__bd">基金管理工具</div>
			<div class="weui-cell__ft"></div>
		</div>
		<div class="weui-cell weui-cell_access">
			<div class="weui-cell__bd">其他</div>
			<div class="weui-cell__ft"></div>
		</div>
	</div>
</div>
<script src="/static/js/jquery-1.12.4.min.js"></script>
<script src="/static/js/jquery-weui.min.js"></script>
<script>
function redirectTo(dom) {
	//
	var target = $(dom).attr('id');
	//
	window.localStorage.setItem("redirect.target", target);
	//
	window.location.href = './' + target;
}

$(document).ready(function() {
	//
	var count = 15;
	//
	var target = window.localStorage.getItem("redirect.target");
	//
	if (target) {
		//
		var t = setInterval(function() {
			//
			$('#' + target).children('.weui-cell__ft').html('将在' + count + '秒后跳转');
			//
			if (0 == count) {
				//
				clearInterval(t);
				//
				$('#' + target).click();
			}
			//
			count--;
		}, 1000);
	}
})
</script>
</body>
</html>
